package com.admin.domain.repository;

import com.admin.domain.modle.Order;
import com.admin.domain.modle.OrderSeat;
import com.admin.interfaces.facade.dto.OrderQueryDTO;

import java.util.Date;
import java.util.List;

/**
 * description 轮播图接口 User: WeiDa Date: 2017-4-11 Time: 16:45
 */
public interface OrderRepository {

    void add(Order order);

    void update(Order order);

    Order get(String code);

    List<Order> list(OrderQueryDTO queryDTO);

    void remove(String code);
    
    void delete(int orderId);

    Order getOrder(int orderId);

    List<OrderSeat> getOrderSeats(int orderId);

    int upsert(Order order);

    int deleteSeat(int orderId);

    int saveSeats(List<OrderSeat> seats);

    int updateWhenPaying(int orderId, String tradeNo, String uname, String phone);

    int updateWhenPaid(String tradeNo, Date payTime);

    int cancelOrder(int orderId);

    int updateRemark(String id, String remark);

    List<Order> listByStatus(String status);

    int verifyOrder(Integer orderId);

    List<Order> listByStatusAndUserId(String status,String userId);
}
